import {requestDelete, requestGet, requestPost, requestPut} from "@/api";

export const getRepositoryList = () => {
    return requestGet('/api/sm/repositories')
}

export const getRepositoryById = (id:string) => {
    return requestGet('/api/sm/repository/'+id)
}


export const saveRepository = (data?:any) => {
    return requestPost("/api/sm/repository",data)
}

export const updateRepository = (data?:any) => {
    return requestPut("/api/sm/repository",data)
}
export const deleteRepository = (id:string) => {
    return requestDelete("/api/sm/repository/"+id)
}
// export const useOrgApi = (id: Number) => {
// 	return service.get('/sm/org/' + id)
// }
//
// export const deleteApi = (id?:string) => {
// 	return service.get('/sm/org/delete/' + id)
// }
//
// export const useOrgSubmitApi = (dataForm: any) => {
// 	if (dataForm.id) {
// 		return service.post('/sm/org/save', dataForm)
// 	} else {
// 		return service.post('/sm/org/save', dataForm)
// 	}
// }
